package SanJiao;

public class Eclipse {
	int b1,b2,b3;

	public Eclipse(int b1, int b2, int b3) {
		super();
		this.b1 = b1;
		this.b2 = b2;
		this.b3 = b3;
	}
	public int ZhouChang() {
		return b1+b2+b3;
	}
	public double MianJi() {
		double S;
		double p;
		p=(b1+b2+b3)/2;
		S = Math.sqrt(p*(p-b1)*(p-b2)*(p-b3));
		return S;
	}
	@Override
	public String toString() {
		return "Triangle [b1=" + b1 + ", b2=" + b2 + ", b3=" + b3 + ", ZhouChang()=" + ZhouChang() + ", MJiani()="
				+ MianJi() + "]";
	}
}
